pmonpp: Pthread Monitor Preprocessor

نویسنده

  • Jinhua Guo
چکیده

Monitors have become an exceedingly important synchronization mechanism because they are a natural generalization of the object-oriented programming. A monitor construct encapsulates private data with public methods to operate on that data. Although the Pthread library contains dozens of functions for threading and synchronization, it does not provide direct support for the monitor. Students must explicitly provide mutual exclusion around “monitor procedures” using mutex locks. However, monitor procedures by definition execute with implicit mutual exclusion. This makes it hard to teach the monitor concept in class and explain the semantic differences between monitors and semaphores. To solve this problem, we have designed and implemented a monitor preprocessor for Pthreads that provides explicit support for monitors in Pthreads.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Light-weight Locks

In this paper, we propose a new approach to building synchronization primitives, dubbed “lwlocks” (short for light-weight locks). The primitives are optimized for small memory footprint while maintaining efficient performance in low contention scenarios. A read-write lwlock occupies 4 bytes, a mutex occupies 4 bytes (2 if deadlock detection is not required), and a condition variable occupies 4 ...

متن کامل

Parallel and Distributed Programming with Pthreads and Rthreads

This paper describes Rthreads (Remote threads), a software distributed shared memory system that supports sharing of global variables on clusters of computers with physically distributed memory. Other DSM systems either use virtual memory to implement coherence on networks of workstations or require programmers to adopt a special programming model. Rthreads uses primitives to read and write rem...

متن کامل

ORION: An Adaptive Home-Based Software Distributed Shared Memory System

In this paper, we describe a multithreaded software distributed shared memory (DSM) system named Orion. It has been developed to provide POSIX-thread (pthread) like interface. We believe this will avoid creating another unique set of application programming interface and ease the porting of pthread programs to a distributed environment. Orion implements home-based consistency model. In this pap...

متن کامل

Locking Aspects in Multithreaded MPI Implementations

MPI implementations rely mostly on locking to provide thread safety and comply with the MPI standard requirements. Yet despite the large body of literature that targets improving lock scalability and finegrained synchronization, little is known about the arbitration aspect of locking and its effect on MPI implementations. In this paper, we provide an in-depth investigation of the correlation be...

متن کامل

Using Pthreads in Fortran

This article describes the way to use pthreads library in Fortran programs. With most of the modern day processors having more and more built in capability of parallelism, there is ample need of utilizing this power at the application level, especially in scientific applications which involves lots of number crunching and multi GB disk handling. To utilize the power of multi threading for scien...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2006